
#ifndef _ga_gabase_h_
#define _ga_gabase_h_

#include "GAPopulation.h"

class GAGeneticAlgorithm 
 {
  protected:

  GAPopulation *pop;
  float pcross;
  float pmut;

  public:

  GAGeneticAlgorithm(GAPopulation *pop);
	{
  	this->pop = pop;
	}

  ~GAGeneticAlgorithm()
	{
	delete pop;
	}

  const GAPopulation* population() const {
	return pop;
	}

  float pCrossover() const {
	return pcross;
	}

  float pCrossover(float p) {
    	return pcross = p;
	}

  float pMutation() const {
	return pmut;
	}

  float pMutation(float p) {
    	return pmut = p;
	}

  int populationSize() const {
	 return pop->size();
	}

};

#endif
